﻿using DAL;
using Model;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace BLL
{
    public class UserInfoManager
    {
        public static List<UserInfo> SelectAllUser(int UserID)
        {
            return UserInfoServies.SelectAlls(UserID);


        }
        //全查
        public static List<UserInfo> SelectAllUserInfo()
        {
            return UserInfoServies.SelectAll();
        }
        public static List<UserInfo> SelectNameUserInfo(string Eml, string Pwd)
        {
            return UserInfoServies.SelectName(Eml, Pwd);
        }
        //模糊查
        public static UserInfo SelectByIDUserInfo(int id)
        {
            return UserInfoServies.SelectByID(id);
        }
        //增
        public static bool InsertUserInfo(UserInfo u)
        {
            return UserInfoServies.Insert(u);
        }
        //删
        public static bool DeleteUserInfo(int id)
        {
            return UserInfoServies.Delete(id);
        }
        //改
        public static bool UpdateUserInfo(int id, UserInfo u)
        {
            return UserInfoServies.Update(id, u);
        }
        public static bool UpdatePwds(string eml,string  pwd)
        {
            return UserInfoServies.UpdatePWD(eml,pwd);
        }
        public static UserInfo CommentSelectAll(string qq)
        {
            return UserInfoServies.SelectByUser(qq);
        }
        public static bool selecttpp(string Eml, string Pwd)
        {
            return UserInfoServies.Selectpp(Eml, Pwd);
        }
    }

}
